/*
    Copyright (c) 2009 Pavol Malosek a.k.a. malo

    This file is part of ComComLib.

    ComComLib is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation; either version 3 of the License, or
    (at your option) any later version.

    ComComLib is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef __LOGGER_HPP_INCLUDED__
#define __LOGGER_HPP_INCLUDED__

#include <lcc/command.hpp>
#include <lcc/device.hpp>

namespace lcc
{

    enum logger_type_t {
        Rxxxx
    };

    enum logger_state_t {
        logger_destroyed,
        logger_iddle,   //  Waiting for a command.
        logger_busy,    //  Processing command.
        logger_ready    //  Command finished results ready.
    };

    struct logger_t {
        logger_type_t type;
        device_t *device;
        volatile logger_state_t state;
        volatile logger_command_name_t cmd_name;
        volatile logger_command_status_t cmd_status;
    };
    
}
#endif

